﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Com.CMS263.PO;

namespace Com.CMS263.DAO
{
    public class TvStationDAO:BaseService
    {
        public IList<Com.CMS263.PO.TVstation> FindList(int pageTv, int pagesizeTv)
        {
            string hql = "from TVstation";
            return FindList<Com.CMS263.PO.TVstation>(hql, null, pagesizeTv * (pageTv - 1), pagesizeTv); 
        }

        public int GetResultCount()
        {
            try
            {
                string hql = "select count(*) from TVstation";
                return int.Parse(GetValue(hql).ToString());
            }
            catch 
            {
                
                return 0;
            }
        }

        public IList<TVstation> FindList()
        {
            string hql = "from TVstation";
            return FindList<Com.CMS263.PO.TVstation>(hql, null,null, null); 
        }
    }
}
